
/**
 * @description 留言模型
 */
const dayjs = require("dayjs");
const mongoose = require("../../../db/db");
const Schema = mongoose.Schema({
    createDate: {
        type: Number,
        default: dayjs()
    },
    articleId:{
        type: String,
        require: true,
    },
    userName: {
        type: String,
        require: true,
        default: "无名"
    },
    msgContext: {
        type: String,
        require: true
    },
    status: {
        type: Number,
        default: 1
    }
})

const MESSAGE=mongoose.model("message",Schema);
module.exports=MESSAGE;